Optimal. Leaf size=82 \[ \frac {\sqrt {b} \tanh ^{-1}\left (\frac {\sqrt {b} \sec (e+f x)}{\sqrt {a+b \sec ^2(e+f x)}}\right )}{f}-\frac {\sqrt {a+b} \tanh ^{-1}\left (\frac {\sqrt {a+b} \sec (e+f x)}{\sqrt {a+b \sec ^2(e+f x)}}\right )}{f} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.09, antiderivative size = 82, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 6, integrand size = 23, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.261, Rules used = {4134, 402, 217, 206, 377, 207} \[ \frac {\sqrt {b} \tanh ^{-1}\left (\frac {\sqrt {b} \sec (e+f x)}{\sqrt {a+b \sec ^2(e+f x)}}\right )}{f}-\frac {\sqrt {a+b} \tanh ^{-1}\left (\frac {\sqrt {a+b} \sec (e+f x)}{\sqrt {a+b \sec ^2(e+f x)}}\right )}{f} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 206
Rule 207
Rule 217
Rule 377
Rule 402
Rule 4134
Rubi steps
\begin {align*} \int \csc (e+f x) \sqrt {a+b \sec ^2(e+f x)} \, dx &=\frac {\operatorname {Subst}\left (\int \frac {\sqrt {a+b x^2}}{-1+x^2} \, dx,x,\sec (e+f x)\right )}{f}\\ &=\frac {b \operatorname {Subst}\left (\int \frac {1}{\sqrt {a+b x^2}} \, dx,x,\sec (e+f x)\right )}{f}+\frac {(a+b) \operatorname {Subst}\left (\int \frac {1}{\left (-1+x^2\right ) \sqrt {a+b x^2}} \, dx,x,\sec (e+f x)\right )}{f}\\ &=\frac {b \operatorname {Subst}\left (\int \frac {1}{1-b x^2} \, dx,x,\frac {\sec (e+f x)}{\sqrt {a+b \sec ^2(e+f x)}}\right )}{f}+\frac {(a+b) \operatorname {Subst}\left (\int \frac {1}{-1-(-a-b) x^2} \, dx,x,\frac {\sec (e+f x)}{\sqrt {a+b \sec ^2(e+f x)}}\right )}{f}\\ &=\frac {\sqrt {b} \tanh ^{-1}\left (\frac {\sqrt {b} \sec (e+f x)}{\sqrt {a+b \sec ^2(e+f x)}}\right )}{f}-\frac {\sqrt {a+b} \tanh ^{-1}\left (\frac {\sqrt {a+b} \sec (e+f x)}{\sqrt {a+b \sec ^2(e+f x)}}\right )}{f}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.13, size = 119, normalized size = 1.45 \[ \frac {\sqrt {2} \cos (e+f x) \sqrt {a+b \sec ^2(e+f x)} \left (\sqrt {b} \tanh ^{-1}\left (\frac {\sqrt {-a \sin ^2(e+f x)+a+b}}{\sqrt {b}}\right )-\sqrt {a+b} \tanh ^{-1}\left (\frac {\sqrt {-a \sin ^2(e+f x)+a+b}}{\sqrt {a+b}}\right )\right )}{f \sqrt {a \cos (2 e+2 f x)+a+2 b}} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.78, size = 496, normalized size = 6.05 \[ \left [\frac {\sqrt {a + b} \log \left (\frac {2 \, {\left (a \cos \left (f x + e\right )^{2} - 2 \, \sqrt {a + b} \sqrt {\frac {a \cos \left (f x + e\right )^{2} + b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right ) + a + 2 \, b\right )}}{\cos \left (f x + e\right )^{2} - 1}\right ) + \sqrt {b} \log \left (\frac {a \cos \left (f x + e\right )^{2} + 2 \, \sqrt {b} \sqrt {\frac {a \cos \left (f x + e\right )^{2} + b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right ) + 2 \, b}{\cos \left (f x + e\right )^{2}}\right )}{2 \, f}, \frac {2 \, \sqrt {-a - b} \arctan \left (\frac {\sqrt {-a - b} \sqrt {\frac {a \cos \left (f x + e\right )^{2} + b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right )}{a + b}\right ) + \sqrt {b} \log \left (\frac {a \cos \left (f x + e\right )^{2} + 2 \, \sqrt {b} \sqrt {\frac {a \cos \left (f x + e\right )^{2} + b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right ) + 2 \, b}{\cos \left (f x + e\right )^{2}}\right )}{2 \, f}, -\frac {2 \, \sqrt {-b} \arctan \left (\frac {\sqrt {-b} \sqrt {\frac {a \cos \left (f x + e\right )^{2} + b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right )}{b}\right ) - \sqrt {a + b} \log \left (\frac {2 \, {\left (a \cos \left (f x + e\right )^{2} - 2 \, \sqrt {a + b} \sqrt {\frac {a \cos \left (f x + e\right )^{2} + b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right ) + a + 2 \, b\right )}}{\cos \left (f x + e\right )^{2} - 1}\right )}{2 \, f}, \frac {\sqrt {-a - b} \arctan \left (\frac {\sqrt {-a - b} \sqrt {\frac {a \cos \left (f x + e\right )^{2} + b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right )}{a + b}\right ) - \sqrt {-b} \arctan \left (\frac {\sqrt {-b} \sqrt {\frac {a \cos \left (f x + e\right )^{2} + b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right )}{b}\right )}{f}\right ] \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [F(-2)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Exception raised: NotImplementedError} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [B] time = 2.01, size = 688, normalized size = 8.39 \[ -\frac {\sqrt {4}\, \sqrt {\frac {b +a \left (\cos ^{2}\left (f x +e \right )\right )}{\cos \left (f x +e \right )^{2}}}\, \cos \left (f x +e \right ) \left (\ln \left (-\frac {2 \left (-1+\cos \left (f x +e \right )\right ) \left (\sqrt {\frac {b +a \left (\cos ^{2}\left (f x +e \right )\right )}{\left (1+\cos \left (f x +e \right )\right )^{2}}}\, \cos \left (f x +e \right ) \sqrt {a +b}+\sqrt {\frac {b +a \left (\cos ^{2}\left (f x +e \right )\right )}{\left (1+\cos \left (f x +e \right )\right )^{2}}}\, \sqrt {a +b}-a \cos \left (f x +e \right )+b \right )}{\sin \left (f x +e \right )^{2} \sqrt {a +b}}\right ) b^{\frac {3}{2}}-2 b^{\frac {3}{2}} \ln \left (-\frac {4 \left (-1+\cos \left (f x +e \right )\right ) \left (\sqrt {\frac {b +a \left (\cos ^{2}\left (f x +e \right )\right )}{\left (1+\cos \left (f x +e \right )\right )^{2}}}\, \cos \left (f x +e \right ) \sqrt {a +b}+\sqrt {\frac {b +a \left (\cos ^{2}\left (f x +e \right )\right )}{\left (1+\cos \left (f x +e \right )\right )^{2}}}\, \sqrt {a +b}-a \cos \left (f x +e \right )+b \right )}{\sin \left (f x +e \right )^{2} \sqrt {a +b}}\right )+2 \arctanh \left (\frac {\left (-1+\cos \left (f x +e \right )\right ) \left (\cos \left (f x +e \right ) \sqrt {4}-2 \cos \left (f x +e \right )-\sqrt {4}-2\right ) \sqrt {b}\, \sqrt {4}}{8 \sin \left (f x +e \right )^{2} \sqrt {\frac {b +a \left (\cos ^{2}\left (f x +e \right )\right )}{\left (1+\cos \left (f x +e \right )\right )^{2}}}}\right ) \sqrt {a +b}\, b -\ln \left (-\frac {2 \left (-1+\cos \left (f x +e \right )\right ) \left (\sqrt {\frac {b +a \left (\cos ^{2}\left (f x +e \right )\right )}{\left (1+\cos \left (f x +e \right )\right )^{2}}}\, \cos \left (f x +e \right ) \sqrt {a +b}+\sqrt {\frac {b +a \left (\cos ^{2}\left (f x +e \right )\right )}{\left (1+\cos \left (f x +e \right )\right )^{2}}}\, \sqrt {a +b}-a \cos \left (f x +e \right )+b \right )}{\sin \left (f x +e \right )^{2} \sqrt {a +b}}\right ) a \sqrt {b}-\ln \left (-\frac {4 \left (\sqrt {\frac {b +a \left (\cos ^{2}\left (f x +e \right )\right )}{\left (1+\cos \left (f x +e \right )\right )^{2}}}\, \cos \left (f x +e \right ) \sqrt {a +b}+a \cos \left (f x +e \right )+\sqrt {\frac {b +a \left (\cos ^{2}\left (f x +e \right )\right )}{\left (1+\cos \left (f x +e \right )\right )^{2}}}\, \sqrt {a +b}+b \right )}{-1+\cos \left (f x +e \right )}\right ) \sqrt {b}\, a -\ln \left (-\frac {4 \left (\sqrt {\frac {b +a \left (\cos ^{2}\left (f x +e \right )\right )}{\left (1+\cos \left (f x +e \right )\right )^{2}}}\, \cos \left (f x +e \right ) \sqrt {a +b}+a \cos \left (f x +e \right )+\sqrt {\frac {b +a \left (\cos ^{2}\left (f x +e \right )\right )}{\left (1+\cos \left (f x +e \right )\right )^{2}}}\, \sqrt {a +b}+b \right )}{-1+\cos \left (f x +e \right )}\right ) b^{\frac {3}{2}}\right ) \left (-1+\cos \left (f x +e \right )\right )}{4 f \sin \left (f x +e \right )^{2} \sqrt {\frac {b +a \left (\cos ^{2}\left (f x +e \right )\right )}{\left (1+\cos \left (f x +e \right )\right )^{2}}}\, \sqrt {b}\, \sqrt {a +b}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \sqrt {b \sec \left (f x + e\right )^{2} + a} \csc \left (f x + e\right )\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [F] time = 0.00, size = -1, normalized size = -0.01 \[ \int \frac {\sqrt {a+\frac {b}{{\cos \left (e+f\,x\right )}^2}}}{\sin \left (e+f\,x\right )} \,d x \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \sqrt {a + b \sec ^{2}{\left (e + f x \right )}} \csc {\left (e + f x \right )}\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________